package com.itheima.day13.thread.test3;

import java.util.concurrent.ExecutionException;
import java.util.concurrent.FutureTask;

public class Test {
    public static void main(String[] args) throws ExecutionException, InterruptedException {
        MyCallable mc1 = new MyCallable();

        FutureTask<String> ft = new FutureTask(mc1);

        Thread t1 = new Thread(ft);

        t1.start();

        String s = ft.get();
        System.out.println(s);
    }
}
